]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
overviewControls: Remove dead code
authorJasper St. Pierre <jstpierre@mecheye.net>
Wed, 18 Sep 2013 23:05:42 +0000 (19:05 -0400)
committerJasper St. Pierre <jstpierre@mecheye.net>
Wed, 30 Oct 2013 17:16:44 +0000 (13:16 -0400)
The parent SlidingControl had an onOverviewShowing, but we had
overridden it with the same code in both subclasses. Just move it
back to SlidingControl.

js/ui/overviewControls.js

index 00007f22a6aa3d2f2d78a243d4d68b47cc6a4f3a..fbf982f228b9430b00b9e91a62339260e4a493f5 100644 (file)
@@ -168,11 +168,10 @@ const SlidingControl = new Lang.Class({
     },
 
     _onOverviewShowing: function() {
-        // reset any translation and make sure the actor is visible when
-        // entering the overview
         this.visible = true;
         this.layout.slideX = this.getSlide();
-        this.actor.translation_x = 0;
+        this.actor.translation_x = this._getTranslation();
+        this.slideIn();
     },
 
     _onWindowDragBegin: function() {
@@ -273,13 +272,6 @@ const ThumbnailsSlider = new Lang.Class({
         return alwaysZoomOut;
     },
 
-    _onOverviewShowing: function() {
-        this.visible = true;
-        this.layout.slideX = this.getSlide();
-        this.actor.translation_x = this._getTranslation();
-        this.slideIn();
-    },
-
     getNonExpandedWidth: function() {
         let child = this.actor.get_first_child();
         return child.get_theme_node().get_length('visible-width');
@@ -340,13 +332,6 @@ const DashSlider = new Lang.Class({
             return 0;
     },
 
-    _onOverviewShowing: function() {
-        this.visible = true;
-        this.layout.slideX = this.getSlide();
-        this.actor.translation_x = this._getTranslation();
-        this.slideIn();
-    },
-
     _onWindowDragBegin: function() {
         this.fadeHalf();
     },